package cn.itcast.client;

import cn.itcast.pojo.Student;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(value = "user-service",fallback = FallbackStudentClient.class)
@Service
public interface StudentClient {
    @GetMapping("user/{id}")
    Student findTne(@PathVariable("id")String id);

}
